﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using com.ClickCricket.bll;

public partial class Admin : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {

    }
    protected void Login1_Authenticate(object sender, AuthenticateEventArgs e)
    {
        int userID = 1;
        com.ClickCricket.bll.Login login = LoginService.Instance.getUser(userID);

        if (Login1.UserName == login.UserName && Login1.Password == login.Password)
        {
            Label1.Text = "Login Successfull";
            Login1.VisibleWhenLoggedIn = false;
            Session["login"] = "admin";
            Response.Redirect("Default.aspx");
        }
    }
}
